package com.liyi.letter.common.result;


import lombok.Getter;

/**
 * 统一返回结果状态信息类
 *
 */
@Getter
public enum ResultCodeEnum {

    SUCCESS(20000,"成功"),
    FAIL(20001, "失败"),
    SERVICE_ERROR(20012, "服务异常"),
    ILLEGAL_REQUEST( 20004, "非法请求"),

    LOGIN_AUTH(20008, "未登陆"),
    PERMISSION(20009, "没有权限"),
    USERNAME_ERROR(20010, "用户名已存在"),
    ;

    private Integer code;

    private String message;

    private ResultCodeEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }
}
